package com.neo.base.actorTest

import scala.actors.Actor

object MyActor1 extends Actor{
  //重新act方法
  def act(){
    for(i <- 1 to 10){
      println("actor1_ " + i)
      Thread.sleep(2000)
    }
  }
}

object MyActor2 extends Actor{
  //重新act方法
  def act(){
    for(i <- 1 to 10){
      println("actor2_ " + i)
      Thread.sleep(2000)
    }
  }
}



object TTTTT{
  def main(args: Array[String]): Unit = {
    MyActor1.start()
    MyActor2.start()
  }
}